package com.ctshk.rpc.starvip.factory.user;

import com.ctshk.rpc.starvip.dto.start_vip.user.Contact;
import com.ctshk.rpc.starvip.dto.start_vip.user.ListOfCtscontactbroadcast;
import com.ctshk.rpc.starvip.dto.start_vip.user.UserInfoChangeNotifyDTO;
import com.ctshk.rpc.starvip.factory.StarVipReqProvider;
import com.ctshk.rpc.starvip.req.user.UserInfoChangeNotifyReq;
import com.google.common.collect.Lists;

/**
 * @BelongsProject: ctshk-cloud
 * @BelongsPackage: com.ctshk.rpc.starvip.factory.user
 * @Author: hef
 * @CreateTime: 2021-04-12 16:45
 * @Description: 描述
 */
public class UserInfoChangeNotifyReqFactory extends StarVipReqProvider<UserInfoChangeNotifyReq> {


    public UserInfoChangeNotifyReqFactory(UserInfoChangeNotifyReq userInfoChangeNotifyReq) {
        super(userInfoChangeNotifyReq);
    }

    @Override
    public UserInfoChangeNotifyDTO produce() {
        UserInfoChangeNotifyDTO dto = new UserInfoChangeNotifyDTO();
        dto.setMessageId("1-KOLM");
        dto.setIntObjectName("CTSContactBroadCast");
        dto.setInterfaceId("CTS_IF_05");
        dto.setOperation("Insert");
        dto.setMessageType("Integration Object");
        dto.setIntObjectFormat("Siebel Hierarchical");
        dto.setListOfCtscontactbroadcast(new ListOfCtscontactbroadcast(Lists.newArrayList(
                new Contact()
                .setContactId(req.getContactId())
                .setCtsContactStatus(req.getCtsContactStatus())
                .setCtsIdentityNum(req.getCtsIdentityNum())
                .setCtsIdentityType(req.getCtsIdentityType())
                .setCellularPhone(req.getCellularPhone())
                .setEmailAddress(req.getEmailAddress())
        )));
        return dto;
    }

}
